package com.chhuang.bean;

/**
 * 增量同步指定操作类
 * @author HuangChen
 *
 */
public class OperateBean {
	private int operate = 0;
	private boolean isDeleteSync = false;
	private String[] idColumns = null;
	public OperateBean() {
		super();
	}
	/**
	 * 
	 * @param operate 0表示执行添加，1表示执行更新，其它表示执行添加或更新（程序查找idColumns的值自行判断）
	 * @param isDeleteSync true表示需要同步删除记录，false表示不需要同步删除记录
	 * @param idColumns 主键或者唯一键（如：id），如果只执行添加并且无需同步删除记录可以为空，其它情况不能为空
	 */
	public OperateBean(int operate, boolean isDeleteSync, String... idColumns) {
		super();
		this.operate = operate;
		this.isDeleteSync = isDeleteSync;
		this.idColumns = idColumns;
	}
	public int getOperate() {
		return operate;
	}
	public void setOperate(int operate) {
		this.operate = operate;
	}
	public boolean isDeleteSync() {
		return isDeleteSync;
	}
	public void setDeleteSync(boolean isDeleteSync) {
		this.isDeleteSync = isDeleteSync;
	}
	public String[] getIdColumns() {
		return idColumns;
	}
	public void setIdColumns(String... idColumns) {
		this.idColumns = idColumns;
	}
}
